import request from '@/utils/request'
import defaultSettings from '@/settings'
import { praseStrEmpty } from '@/utils/ruoyi'

//业务撤销申请录入查询
export const apiUrlConfigEntryQuery = {
  queryUrl: `${defaultSettings.ctx.cnapsApp}/bsInformation/businessUndo/BusinessUndoEntry/search`,
}


// 业务撤销申请录入详情
export function businessUndoEntryDetail(data) {
  return request({
    url: `${defaultSettings.ctx.cnapsApp}/bsInformation/businessUndo/BusinessUndoEntry/detail`,
    method: 'get',
    params: { oriId:data.oriId,oriSysCode:data.oriSysCode }
  })
}

// 业务撤销申请录入详情
export function businessUndoEntryDetailSave(data,sysCode) {
  return request({
    url: `${defaultSettings.ctx.cnapsApp}/bsInformation/businessUndo/BusinessUndoEntry/save`,
    method: 'post',
    data:data,
    params:{sysCode:sysCode}
  })
}




//业务撤销申请审核查询
export const apiUrlConfigApproveQuery = {
  queryUrl: `${defaultSettings.ctx.cnapsApp}/bsInformation/businessUndo/BusinessUndoApprove/search`,
}


// 业务撤销申请审核详情
export function businessUndoApproveDetail(data) {
  return request({
    url: `${defaultSettings.ctx.cnapsApp}/bsInformation/businessUndo/BusinessUndoApprove/detail`,
    method: 'get',
    params: { id:data.id}
  })
}

// 业务撤销申请审核详情
export function businessUndoApproveApprove(data) {
  return request({
    url: `${defaultSettings.ctx.cnapsApp}/bsInformation/businessUndo/BusinessUndoApprove/approve`,
    method: 'post',
    data:data
  })
}

export function businessUndoApproveReject(data) {
  return request({
    url: `${defaultSettings.ctx.cnapsApp}/bsInformation/businessUndo/BusinessUndoApprove/reject`,
    method: 'post',
    data:data
  })
}


//业务撤销申请查询
export const apiUrlConfigQuery = {
  queryUrl: `${defaultSettings.ctx.cnapsApp}/bsInformation/businessUndo/BusinessUndoQuery/search`,
}


// 业务撤销申请查询详情
export function businessUndoQueryDetail(data) {
  return request({
    url: `${defaultSettings.ctx.cnapsApp}/bsInformation/businessUndo/BusinessUndoQuery/detail`,
    method: 'get',
    params: { id:data.id}
  })
}
